/*
 * @Description:
 * @Author: sheng.xia
 * @Date: 2021-12-07 19:52:44
 */
export default {
    // 定义 model 的初始 state
    state: {
        workTime: 25,
        shortRest: 5,
        longRest: 15,
        longInterval: 4,
        disableRest: false,
        autoRest: true,
        autoFoucs: false,
        taskData: {
            // work: { title: '专注', time: 5 },
            // rest: { title: '休息', time: 3 },
            // longRest: { title: '长休息', time: 4 },
            work: { title: '专注', time: 25 * 60 },
            rest: { title: '休息', time: 5 * 60 },
            longRest: { title: '长休息', time: 15 * 60 },
        }
    },
    // 定义改变该模型状态的纯函数
    reducers: {
        update(prevState, payload) {
            return {
                ...prevState,
                ...payload,
            };
        },
    },
};